package com.hd.appcommon.mapper;

import com.hd.appcommon.entity.CourseScore;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
 * (CourseScore)表数据库访问层
 *
 * @author makejava
 * @since 2023-07-04 11:46:00
 */
@Repository
@Mapper
public interface CourseScoreMapper extends BaseMapper<CourseScore>{

    public int courseCreditSync(@Param("sno")String sno,@Param("year")String year,@Param("term")String term);
    @Select("select DISTINCT year from course_score")
    List<CourseScore> getSchoolYear();
    @Select("select DISTINCT year from course_score where sno=#{sno}")
    List<CourseScore> getSchoolYearBySno(@Param("sno")String sno);
}

